﻿namespace RuoTeng.Windows.Forms
{
   using System;

   static class Resources
    {
        private static System.Reflection.Assembly _Assembly;

        private static System.Reflection.Assembly Assembly
        {
            get {
                if (_Assembly == null)
                {
                    _Assembly = System.Reflection.Assembly.GetExecutingAssembly();
                }
                return _Assembly;
            }
        }    
       private static System.Drawing.Bitmap GetImage(string name)
       {
          System.IO.Stream stream = Assembly.GetManifestResourceStream("Rtools.ruoteng.control.Resources." + name);         
          if (stream != null)
          {
              return (System.Drawing.Bitmap)System.Drawing.Image.FromStream(stream);
          }
          return null;
       }

       internal static System.Drawing.Bitmap Vip
       {
          get{
              return GetImage("vip.jpg");
             }
       }

       internal static System.Drawing.Bitmap Update
       {
           get
           {
               return GetImage("update.jpg");
           }
       }


       internal static System.Drawing.Bitmap Announce
       {
           get
           {
               return GetImage("announce.gif");
           }
       }

       internal static System.Drawing.Bitmap Buy
       {
           get
           {
               return GetImage("buy.gif");
           }
       }

       internal static System.Drawing.Bitmap Xieyi
       {
           get
           {
               return GetImage("xieyi.gif");
           }
       }
    }
}
